{extend name="public/base"}

{block name="style"}
<link rel="stylesheet" href="__STATIC__/admin/css/news.css" media="all" />
{/block}


{block name="main"}
<body class="childrenBody">
<blockquote class="layui-elem-quote news_search">
    <form class="layui-form" action="?">
        <div class="layui-inline">
            <div class="layui-input-inline">
                <input type="text" value="" placeholder="生成二维码数量" class="layui-input">
            </div>
        </div>
        <div class="layui-inline">
            <div class="layui-input-inline">
                <input type="text" value="" placeholder="打包数量" class="layui-input">
            </div>
        </div>
        <div class="layui-inline">
            <div class="layui-input-inline">
                <input type="text" value="" placeholder="每包数量" class="layui-input">
            </div>
            <a class="layui-btn create_btn">生成</a>
        </div>
    </form>
</blockquote>
{/block}

{block name="javascript"}
<script>
    layui.config({
        base : "js/"
    }).use(['form','layer','jquery', 'laydate'],function() {
        var layer = parent.layer === undefined ? layui.layer : parent.layer, $ = layui.jquery;

        $(".create_btn").click(function () {
            var _form = $('form');
            $.ajax({
                type : 'POST',
                url : _form.attr('action'),
                data : _form.serialize(),
                dataType : 'json',
                success : function (msg) {
                    console.log(msg);
                }
            });
        });
    });
</script>
{/block}